-
Backward compatibility in the plug-in
Until now, item stacks created with an older version of your
item set wouldn't update all of their properties once you
upload a new item set to your server: if you change the
attribute modifiers of a custom item, the item stacks created
previously will keep their old value of that attribute modifier.
This would require you to replace all these items manually with
a newer variant, or accept this suboptimal situation.
The problem sketched above is now solved, or... well... sort of.
All item stacks in your server that are created with a version of
the plugin before 8.0 will no longer be treated as custom
items and will lose parts of their properties. This was needed
because I radically changed the way custom items are recognized.
On the bright side, all item stacks created with a version of the
plugin at or after 8.0 will automatically receive updates
whenever you load a new version of your item set. In the current
implementation, the plugin will scan the inventory of all players
every 5 seconds and upgrade all old items it finds. It will do
a best attempt to handle player modifications such as extra
enchantments and lost durability, but this behavior will not
always be exactly what you want (but should still be reasonable).
This comes with a couple of other changes:
-
The INTERNAL item damage is from now on truly internal: you
won't be able to see it or modify it (and thus never have
to worry about it again.)
-
Item stacks belonging to custom items will store the name
of that custom item in their NBT, as well as some other
information that it needs to perform good item upgrading.
The durability is from now on also stored in the NBT,
but is still visible in the lore.
-
Changing the name of custom items is no longer
allowed. (When item stacks are created on the server, the
name of its custom item is stored in its nbt. If that name
would be changed, problems would occur...) Note that
changing the display name is still allowed.
-
When you delete a custom item, the plugin will also delete
all item stacks that belong to that custom item.
Furthermore, once a custom item is deleted, it is no longer
allowed to create new custom items with the name of that
deleted custom item. (An item stack belonging to the deleted
custom item might be locked away in some chest for a long time.
When a player would pick the item up, the plugin would think
that item would belong to the new custom item with the name of
that deleted custom item...)
-
Decreasing the stack size of custom items is no longer allowed.
(If the custom item used to have a bigger stacksize, players
might still be carrying such item stacks around...)
-
Due to this new upgrading system, the old command block
help option is removed. (You shouldn't need it anymore and it
causes problems because the NBT of custom item stacks is
quite complex.)
-
To make the regular command block help more useful, the item
upgrader will also upgrade the equipment of mobs when they
spawn.
-
Armor appearence
This update also makes it possible to change the appearance of
worn custom armor... under the right circumstances.
-
It adds 3d helmets. These are special custom items that are
ironically not helmets, but you can still equip them
(the plugin will take care of that). This sounds silly, but
it allows you to give it a custom item model, which will
even be shown when the helmet is equipped! Unfortunately,
this is quite complicated because you will have to design
the item model yourself. Unless someone is nice enough
to publish a convenient model!
-
It also adds worn armor textures. This allows you to
customize the armor texture that is displayed when players
(or mobs) equip your custom armor. Unfortunately, they will
only be visible to players with the Optifine mod installed.
And sorry Guaz, I'm afraid this ruins your first tutorial
a bit ;(
But, I did follow that tutorial as the basis of my
implementation.
-
Drops and output tables
This update also adds the possibility of randomness to custom
containers, mob drops, and block drops, as well as some other
related improvements. This randomness comes in the form of an
output table, which is basically a list of pairs of
possible outputs and the chance that particular output is chosen.
-
Before this update, mob drops and block drops allowed some
randomness: you were able to choose the chance to drop,
the minimum amount to drop, and the maximum amount to drop.
This system is replaced with output tables, which means you
can decide the exact chance to drop which amount (and which
item).
-
Custom containers didn't allow any randomness at all until
this update. But with this update, the outputs of container
recipes use output tables rather than just 1 item, so you
can now truly implement random recipes. Note: if multiple
different items can be dropped, the container will be blocked
whenever an item is put in a randomized output slot until
the player removes that item from that randomized output
slot.
-
The new system for mob drops and block drops also makes it
possible to drop some items only when the player uses the
right custom item to destroy the block or kill the mob.
-
Until now, recipes were only able to produce custom items,
simple vanilla items, and vanilla items with a datavalue.
And even worse, mob drops and block drops could only drop
custom items. This update adds the possibility to produce
a complex item: you can use any item stack on your
server.
-
Remaining features
This update also adds a couple of features that are not really
related to each other:
-
Equipped potion effects
Make it possible to give players potion effects as
long as they are equipping the right custom item in
the right slot.
-
Attack range
Makes it possible to change the attack range of a
player when he has the right custom item in his
main hand. For instance spears with extra long range
and daggers with a shorter range.
-
Extra NBT
Makes it possible to give additional NBT tags to
custom items. This can be useful for interaction
with other plug-ins that check the NBT of items.
Currently, this is limited to adding integers and
strings, but this can be improved if there is
enough interest.
-
Item aliases
Until now, the /ci give command only accepts
the full names of custom items. But from now on,
they also accept the aliases of custom items. This
can spare you time if your items have long names
(and especially since renaming is no longer allowed).
-
Replacing items on right-click
This update has added the possibility to replace an item when you right click, based on conditions you can specify beforehand. You can make these conditions as simple or
complex as you want, requiring for instance the presence of at least 1 other item, or having multiple conditions requiring several items to be present and/or missing. Now
your complex resource swapping mechanism can be implemented, hooray!
-
Placeholders for input, output, and fuel slots
This update also makes it possible to give
placeholder items to input, output, and fuel slots
of custom containers. These are items that will be
shown when its slot does not container any
items, but will vanish once the player inserts an
item.
-
Getting help
Note that almost every page in the Editor has a small question
mark button on the top-left of the window. Clicking it will open
a webpage that explains everything on that page. Please use this
before asking help with the new features.
When not everything works at your server, you can also use the
/kci debug command. If your installation is not too
broken, this command will tell you if any startup errors occurred,
and will check your server resourcepack (get the url from
your server.properties, try to download it, check that it is a
valid resourcepack, check that the sha1 hash is correct...).
-
Technical improvements
This update also introduces some technical improvements and
bugfixes:
-
You can now also use the /kci ... instead of just
the /ci ... command. This is useful because the
old one has some conflicts with an Essentials command.
-
Until now, the images in the .cisb file were stored in
a very simple, but expensive format: it took 4 bytes
per pixel. From now on, the editor will use the PNG
format instead, which reduces the occupied disk space
dramatically.
-
Those with a lot of items and containers might have noticed
that saving (and exporting) could take multiple seconds. I
got rid of the most important performance bottleneck, which
divides the time needed to save by ~10.
-
This update improves the way shift-clicking and
collect-to-cursor, and dragging inventory actions are
handled in custom containers.
-
The Editor will perform 'system tests' upon startup: it will
check if it is able to do some actions like saving and
reading files. If it is not able to do so, the user will be
warned. (Some anti virus software seems to prevent the
Editor from doing this. Until now, people would see a red
message on top of the editor upon exporting rather than
a warning upfront.)
-
Improve the way custom containers handle custom lore and
display names in slot displays.
-
Container recipes will no longer proceed if one of the
unused input slots is not empty.
-
You can no longer delete custom items that are still being
used in container recipes. In the past, this was allowed
(by accident), and corrupted the entire item set.
-
Improved the crafting and progress indicators of containers
slightly (the stacksize is now more consistent).
-
Fixed a bug that would prevent custom containers from
being reloaded when using the /ci reload
command.
-
Fixed a bug that would occur when removing ingredients
from container recipes.